<!--{include(file='head.html')}-->
<div class="main">
	<table cellspacing="0" cellpadding="0" border="0" class="contentMain">
		<tr valign="top">
			<td id="whotd"><!--{include(file='left.html')}--></td>
			<td>
				<div class="rightcontent">
				<div class="filter-tools">
					<span class="filter-keyword">
						<form action="<!--{url('admin','type','property')}-->" name="seaform" id="seaform" method="post">
							按类目：
							<select name="typeid" id="typeid">
								<!--{$option}-->
							</select>
						</form>
					</span>
					<span class="hintoper"></span>
					<span class="right">
<input type="button" value="刷新" class="long-button" onclick="$.oper.refresh()"/>
<input type="button" value="移除" class="long-button" onclick="$.oper.remove()"/>
<input type="button" value="添加" class="long-button" onclick="$.oper.add('type','propertyadd','typeid=<!--{$typeid}-->')"/>
					</span>
				</div>
				<div class="adminpagetop"></div>
				<div class="list-content">
						<table cellspacing="0" cellpadding="0" border="0" class="listtable">
							<thead>
								<tr>
									<th width="10%">
										<input type="checkbox" value="1" name="allselect" id="allselect" autocomplete="off" onclick="$.oper.selectall()"/>
									</th>
									<th width="10%">类目编号</th>
									<th width="10%">操作</th>
									<th width="10%" align="left">类目名称</th>
									<th width="10%">类型</th>
									<th width="30%">可选项</th>
									<th width="10%">排序</th>
								</tr>
							</thead>
							<tbody id="listtbody">
								<!--{foreach $properties property}-->
								<tr onmouseover="$.oper.addcolor(this)" onmouseout="$.oper.removecolor(this)" id="tr_<!--{$property.propertyid}-->">
									<td>
										<input type="checkbox" value="<!--{$property.propertyid}-->" name="singleselect" autocomplete="off"/>
									</td>
									<td><!--{$property.propertyid}--></td>
									<td>
										<a href="<!--{url('admin','type','propertyedit','propertyid=$property.propertyid')}-->">编辑</a>
									</td>
									<td align="left">
										<span onclick="$.oper.edit(this,'propertyname','<!--{$property.propertyid}-->')" title="点击修改属性" class="edit" onmouseover="$.oper.bgcolor(this,'on')" onmouseout="$.oper.bgcolor(this,'off')"><!--{$property.propertyname}--></span>
									</td>
									<td>
										<!--{if $property.dptype == 1}-->
											选择项可筛选
										<!--{elseif $property.dptype == 2}-->
											选择项不可筛选
										<!--{elseif $property.dptype == 3}-->
											输入项可筛选
										<!--{elseif $property.dptype == 4}-->
											输入项不可筛选
										<!--{/if}-->
									</td>
									<td>
										<!--{if $selvals[$property.propertyid]}-->
											<!--{implode(",",$selvals[$property.propertyid])}-->
										<!--{else}-->
											--
										<!--{/if}-->
									</td>
									<td>
										<span onclick="$.oper.edit(this,'order','<!--{$property.propertyid}-->')" title="点击修改排序" class="edit" onmouseover="$.oper.bgcolor(this,'on')" onmouseout="$.oper.bgcolor(this,'off')"><!--{$property.order}--></span>
									</td>
								</tr>
								<!--{/foreach}-->
							</tbody>
						</table>
						<input type="hidden" value="<!--{$typeid}-->" name="typeid"/>
				</div>
			</div>
			</td>
		</tr>
	</table>
</div>
<!--{include(file='foot.html')}-->
<script type="text/javascript">
$(function(){
	$.oper.init("<!--{url('admin','type','propertysave')}-->");
	$("#typeid").change(function(){
		$.oper.seasubmit();
	});
});
</script>

